
package com.ncloud.billing.mapper;

import java.util.List;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;

import com.ncloud.billing.entity.BsContract;
@Mapper
public interface BsContractMapper {
	@Select(value = {"SELECT project_id, child_contract_inst_id, contract_inst_id, contract_id, contract_name, file_path, sign_date, exp_date, eff_date,"
	 		+ "sale_id, state, create_time, create_user, update_time, update_user, remark FROM bs_contract where project_id = #{project_id}"})
	@Results({ @Result(column = "project_id", property = "projectId"), @Result(column = "child_contract_inst_id", property = "childContractInstId"),
	   @Result(column = "contract_inst_id", property = "contractInstId"),@Result(column = "contract_id", property = "contractId"),
	   @Result(column = "contract_name", property = "contractName"),@Result(column = "file_path", property = "filePath"),
	   @Result(column="sign_date",property="signDate"),@Result(column="exp_date",property="expDate"),
	   @Result(column="eff_date",property="effDate"),@Result(column="sale_id",property="saleId"),
	   @Result(column="state",property="state"),@Result(column="create_time",property="createTime"),
	   @Result(column="create_user",property="createUser"),@Result(column="update_time",property="updateTime"),
	   @Result(column="update_user",property="updateUser"),@Result(column="remark",property="remark")})
	public List<BsContract> getBsContractByProjectID(Long project_id);
}



